Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use rfc6749 to standardize authorization code feature #107

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

jmcartlamy
Copy link

@jmcartlamy jmcartlamy commented Oct 16, 2019

Currently, OAuth 2.0 Authorization Code flow is an experimental feature and doesn't use the good way to process the authorization code response.

Indeed, append a header Authorization with an encoding in base64 client_id+ client_secret doesn't work if the server which hosts the token endpoint follow the standards.


So, this commit follow the rfc6749 and standardize authorization code feature.

Moreover, client_secret is not required during the access token request. However, if the token endpoint ask it, the dev' just add it in the configuration and it will be automatically add in the parameters.

Edit: To resolve async issue on callback function (See issue #103), we return a Promise instead of undefined. Documentation has been improved in this way.

Edit 2: Sometimes, an user can keep code and state in the url parameters. JSO throw an error but in most of cases, tokens & authorization are ok. Now, we just log a line said it could not find retrieve state object.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant